/* 登录页面特定样式 */

body {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    background: linear-gradient(135deg, #6e8efb, #a777e3);
    background-size: cover;
    font-family: 'Arial', sans-serif;
    position: relative;
    overflow: hidden;
}

body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url('https://source.unsplash.com/random/1920x1080/?pattern');
    background-size: cover;
    opacity: 0.1;
    z-index: -1;
}

/* 动画背景 */
.animated-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: -2;
}

.animated-shape {
    position: absolute;
    border-radius: 50%;
    opacity: 0.2;
}

.shape1 {
    width: 600px;
    height: 600px;
    background: linear-gradient(45deg, #6e8efb, transparent);
    top: -150px;
    left: -150px;
    animation: float 15s infinite alternate;
}

.shape2 {
    width: 500px;
    height: 500px;
    background: linear-gradient(-45deg, #a777e3, transparent);
    bottom: -150px;
    right: -150px;
    animation: float 20s infinite alternate-reverse;
}

.shape3 {
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, #e66465, transparent);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation: pulse 8s infinite;
}

@keyframes float {
    0% {
        transform: translate(0, 0) rotate(0deg);
    }
    100% {
        transform: translate(150px, 50px) rotate(15deg);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.2;
    }
    50% {
        transform: translate(-50%, -50%) scale(1.5);
        opacity: 0.1;
    }
}

.login-container {
    background-color: rgba(255, 255, 255, 0.95);
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    width: 100%;
    max-width: 400px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    position: relative;
    z-index: 1;
    transform: translateY(0);
    transition: transform 0.3s, box-shadow 0.3s;
    overflow: hidden;
}

.login-container:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.login-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(90deg, #6e8efb, #a777e3);
    z-index: 2;
}

.login-header {
    text-align: center;
    margin-bottom: 35px;
}

/* Logo图标 */
.logo-circle {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #6e8efb, #a777e3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.logo-circle i {
    font-size: 36px;
    color: white;
}

.login-header h1 {
    color: #333;
    font-size: 28px;
    margin-bottom: 10px;
    font-weight: 600;
}

.login-header p {
    color: #666;
    font-size: 15px;
}

.form-group {
    margin-bottom: 24px;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #555;
    font-size: 14px;
    font-weight: 500;
}

.form-group label i {
    color: #a777e3;
    margin-right: 5px;
}

.form-group input {
    width: 100%;
    padding: 14px 18px;
    border: 1px solid #e1e1e1;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s;
    background-color: rgba(255, 255, 255, 0.9);
    color: #333;
}

.form-group input:focus {
    border-color: #a777e3;
    box-shadow: 0 0 0 3px rgba(167, 119, 227, 0.2);
    outline: none;
}

.error-message {
    background-color: rgba(244, 67, 54, 0.1);
    color: #f44336;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 24px;
    display: none;
    font-size: 14px;
    border-left: 4px solid #f44336;
    animation: fadeIn 0.3s;
}

.login-button {
    width: 100%;
    padding: 15px;
    background: linear-gradient(90deg, #6e8efb, #a777e3);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.login-button i {
    margin-right: 8px;
}

.login-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.login-button:hover {
    background: linear-gradient(90deg, #5a7df4, #9560d1);
    box-shadow: 0 5px 15px rgba(106, 142, 251, 0.4);
    transform: translateY(-2px);
}

.login-button:hover::before {
    left: 100%;
}

.login-button:active {
    transform: translateY(0);
    box-shadow: 0 2px 5px rgba(106, 142, 251, 0.4);
}

/* 成功状态 */
.login-button.success {
    background: linear-gradient(90deg, #28a745, #20c997);
    box-shadow: 0 5px 15px rgba(40, 167, 69, 0.4);
}

/* 登录成功动画 */
.success-animation {
    animation: successPulse 0.8s;
}

@keyframes successPulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

/* 抖动效果 */
.shake {
    animation: shake 0.5s;
}

@keyframes shake {
    0%, 100% {
        transform: translateX(0);
    }
    10%, 30%, 50%, 70%, 90% {
        transform: translateX(-5px);
    }
    20%, 40%, 60%, 80% {
        transform: translateX(5px);
    }
}

.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
    margin-right: 10px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 登录页脚 */
.login-footer {
    text-align: center;
    margin-top: 30px;
    color: #888;
    font-size: 13px;
}

.login-footer .highlight {
    color: #a777e3;
    font-weight: 500;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 添加返回首页的链接样式 */
.back-home {
    display: inline-block;
    margin-top: 10px;
    color: #4a90e2;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s;
}

.back-home:hover {
    color: #3572b0;
    text-decoration: underline;
}

@media (max-width: 480px) {
    .login-container {
        padding: 30px 20px;
        margin: 0 20px;
    }
    
    .logo-circle {
        width: 70px;
        height: 70px;
    }
    
    .logo-circle i {
        font-size: 30px;
    }
} 